package com.yanqu.road.logic.pb;

import com.yanqu.road.entity.activity.tongbing.data.CrossTongBingPatrons;
import com.yanqu.road.entity.activity.tongbing.data.CrossTongBingTeam;
import com.yanqu.road.pb.activity.TongBingProto;

import java.util.List;
import java.util.Map;
import java.util.concurrent.ConcurrentHashMap;

public class CrossTongBingPb {

    public static Map<Integer, CrossTongBingPatrons> parseCrossTongBingPatrons(List<TongBingProto.TongBingPatronsTempMsg> msgList) {
        Map<Integer, CrossTongBingPatrons> patronsMap = new ConcurrentHashMap<>();
        for (TongBingProto.TongBingPatronsTempMsg msg : msgList) {
            patronsMap.put(msg.getId(), new CrossTongBingPatrons(msg.getId(), msg.getSkin(), msg.getAbility()));
        }
        return patronsMap;
    }

}
